import React,{useState} from 'react'

export default function StateCom() {
    
    let [count,setCount] = useState('true')

    let handleClick = ()=>{
        setCount(count + 1)
    }
  return (
    <div>
        <h2>{count}</h2>
        <button onClick={handleClick}>自增</button>
    </div>
  )
}
